<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="/include/jstl.jsp" %>
<script type="text/javascript">
function checkNo(){
  var reg0=/^0?(13[0-9]|15[012356789]|18[0236789]|14[57])[0-9]{8}$/;
  var reg1=/(\d{3}-\d{8})|(\d{4}-\d{7})/;  
  var num=$("#CUST_LOGIN").val();
  var reg2=/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+((\.[a-zA-Z0-9_-]{2,3}){1,2})$/;
  
  if(reg0.test(num)||reg1.test(num)){
    return true;
  }else if(reg2.test(num)){
       return true;
  }
  if(num==''||num==null){
    return true;
  } else{
    alert("登录账号格式不正确！");
    return false;
  }
}  

function checkEmail(){
   var reg0=/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+((\.[a-zA-Z0-9_-]{2,3}){1,2})$/;
   var num=$("#USR_EMAIL").val();
   if(reg0.test(num)){
       return true;
     }
     if(num==''||num==null){
    return true;
  }
     else{
       alert("邮箱格式不正确！");
       document.getElementById("USR_EMAIL").value=" ";
       return false;
     }
}
</script>

<form id="pagerForm" method="post" action="412300.stp">
      <input type="hidden" name="pageNum" value="${ETF.PAGENUM}" /><!--当前第几页-->
      <input type="hidden" name="START_DAT" value="${ETF.START_DAT}"/>
      <input type="hidden" name="END_DAT" value="${ETF.END_DAT}"/>
      <input type="hidden" name="USR_MOBILE" value="${ETF.USR_MOBILE}"/>
      <input type="hidden" name="CUST_LOGIN" value="${ETF.CUST_LOGIN}"/>
      <input type="hidden" name="CUST_NAME" value="${ETF.CUST_NAME}"/>
      <input type="hidden" name="CUST_STATUS" value="${ETF.CUST_STATUS}"/>
      <input type="hidden" name="USR_STATUS" value="${ETF.USR_STATUS}"/>
      <input type="hidden" name="USR_EMAIL" value="${ETF.USR_EMAIL}"/>
      <input type="hidden" name="CUST_CRED_NO" value="${ETF.CUST_CRED_NO}"/>
      <input type="hidden" name="CUST_CRED_TYPE" value="${ETF.CUST_CRED_TYPE}"/>
</form>
<div class="pageHeader">
  <form onsubmit="return navTabSearch(this);" action="412300.stp" method="post">
  <div class="searchBar">
    <table class="searchContent">
      <tr>
         <td>登录账号:</td>
         <td>
             <input type="text" size="23" maxlength="64" id="CUST_LOGIN"  name="CUST_LOGIN" value="${ETF.CUST_LOGIN}" onblur="checkNo()"/>
         </td>
         <td>用户名称:</td>
         <td>
             <input type="text" size="23" maxlength="64" id="CUST_NAME"  name="CUST_NAME" value="${ETF.CUST_NAME}"/>
         </td>
         <td>证件号码:</td>
         <td>
             <input type="text" size="23" maxlength="18" id="CUST_CRED_NO"  name="CUST_CRED_NO" value="${ETF.CUST_CRED_NO}"  />
         </td> 
      </tr>
     <tr> 
         <td>证件类型:</td>
         <td>
           <select name="CUST_CRED_TYPE" id="CUST_CRED_TYPE">
             <option value="-1" select="select">--请选择--</option>
             <option value="0"  > 居民身份证</option>
             <!--option value="1"  > 护照</option>
             <option value="2"  > 军官证</option>
             <option value="C"  > 台湾居民身份证</option>
             <option value="F"  > 临时身份证</option>
             <option value="G"  > 警察证</option>
             <option value="I"  > 港澳身份证</option>
             <option value="Z"  > 其他</option-->
           </select>
         </td>
         <td>用户状态:</td>
         <td>
           <select name="CUST_STATUS" id="CUST_STATUS">
             <option value="-1" select="select">--请选择--</option>
             <option value="0">正常</option>
             <option value="9">注销</option>
           </select>
         </td>
         <td>注册日期:</td>
         <td colspan="3">
            <input type="text" name="start_Dat"  class="date" readonly="true"  value="${ETF.START_DAT}"/>
            ~
            <input type="text" class="date" readonly="true" name="end_Dat" value="${ETF.END_DAT}"/>
         </td> 
          
     </tr>
    </table>
     <div class="subBar">
        <ul>   
          <li><div class="buttonActive"><div class="buttonContent"><button type="submit">查询</button></div></div></li>
        </ul>
     </div>

  </div>
  </form>
</div>
<div class="pageContent">
  <div class="panelBar">
    
  </div>
  <table class="table" width="100%" layoutH="174">
    <thead>
      <tr>
        <th width="13%">登录账号</th>
        <th width="10%">用户名称</th>
        <th width="10%">证件类型</th>
        <th width="13%">证件号码</th>
        <th width="10%">注册日期</th>
        <th width="7%">用户状态</th>
        <th width="7%">认证状态</th>
        <th width="16%">操&nbsp;&nbsp;作</th>
      </tr>
    </thead>
    <tbody>
      <c:if test="${ETF.RSPCOD==01004}">没有符合条件的记录</c:if>  
      <c:choose>
        <c:when test = "${ETF.RSPCOD eq '10001'}">
          <tr>
              <td colspan="7"><font  style="vertical-align:middle;font-size:16px;">${ETF.RSPMSG}</font></td>
          </tr>
        </c:when>
        <c:when test = "${ETF.RSPCOD eq '10002'}">
          <tr>
              <td colspan="7"><font  style="vertical-align:middle;font-size:16px;">${ETF.RSPMSG}</font></td>
          </tr>
        </c:when>
            <c:otherwise >
                <c:forEach items="${ETF.GRP}" var="GRP">
                  <tr target="sid_user" rel="1">
                    <td>${GRP.CUST_LOGIN}</td>
                    <td>${GRP.CUST_NAME}</td>
                    <td>
                      <c:if test="${GRP.CUST_CRED_TYPE=='0'}">居民身份证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='1'}">护照</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='2'}">军官证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='3'}">回乡证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='4'}">户口本</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='9'}">企业营业执照</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='C'}">台湾居民身份证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='D'}">外国公民护照</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='F'}">临时身份证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='G'}">警察证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='H'}">士兵证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='I'}">港澳身份证</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='J'}">勘察证件</c:if>
                      <c:if test="${GRP.CUST_CRED_TYPE=='Z'}">其他</c:if>
                    </td>
                    <td>${GRP.CUST_CRED_NO}</td>
                    <td>${GRP.CUST_REG_DATE}</td>
                    <td>
                      <c:if test="${GRP.CUST_STATUS=='0'}">正常</c:if>
                      <c:if test="${GRP.CUST_STATUS=='9'}">注销</c:if>
                    </td><td>
                        <c:if test="${GRP.USR_STATUS=='0'}">未认证</c:if>
                        <c:if test="${GRP.USR_STATUS=='1'}">审核中</c:if>
                        <c:if test="${GRP.USR_STATUS=='2'}">已通过</c:if>
                        <c:if test="${GRP.USR_STATUS=='3'}">未通过</c:if>
                        <c:if test="${GRP.USR_STATUS=='4'}">证件到期</c:if>
                    </td>
                    <td>
                    <div>
                       <c:if test="${ETF.CON_BUT_DEV==0 || (ETF.CON_BUT_DEV==1 && ETF.BUT_LOOK ==1)}"> 
                         <a  href="412301.stp?CUST_ID=${GRP.CUST_ID}" title="详 情" target="navTab"><font color="#15428b">详 情</font></a>
                         | <a  href="unLockPwdforward.stp?CUST_ID=${GRP.CUST_ID}&CUST_LOGIN=${GRP.CUST_LOGIN}&CUST_CRED_TYPE=${GRP.CUST_CRED_TYPE}&CUST_CRED_NO=${GRP.CUST_CRED_NO}&flag=0" title="密码解锁" target="navTab"><font color="#15428b">密码解锁</font></a>
                         <c:if test="${GRP.CUST_STATUS=='0'}">
                         | <a  href="412216.stp?CUST_ID=${GRP.CUST_ID}&PG_AC_STATUS=9" title="确实要注销吗？" target="ajaxTodo"><font color="#15428b">注 销</font></a>
                         </c:if>
                         <c:if test="${GRP.CUST_STATUS=='9'}">
                         | <a  href="412216.stp?CUST_ID=${GRP.CUST_ID}&PG_AC_STATUS=0"   title="确定激活吗？" target="ajaxTodo" ><font color="#15428b">激 活</font></a>
                         </c:if>
                         
                       </c:if>
                    </div>
                    </td>
                  </tr>
                  </c:forEach>
            </c:otherwise>
       </c:choose>
    </tbody>
  </table>
  <div class="panelBar">
         <ul class="toolBar">
      <li><a class="icon" href="preDownLoad.stp?PAGENUM=${ETF.PAGENUM}&expr_START_DAT=${ETF.START_DAT}&expr_END_DAT=${ETF.END_DAT}&expr_CUST_NAME=${ETF.CUST_NAME16}&expr_CUST_CRED_NO=${ETF.CUST_CRED_NO}&expr_CUST_STATUS=${ETF.CUST_STATUS}&expr_CUST_LOGIN=${ETF.CUST_LOGIN}&expr_CUST_CRED_TYPE=${ETF.CUST_CRED_TYPE}&EXPORT_TYPE=412303&AUTH_OBJECT=0"
        target="ajaxTodo" title="确定导出这些记录吗?"><span>导出EXCEL</span></a></li>
      </ul>
      <div class="pages"><span>共[${ETF.TOLCNT}]条,当前第${(ETF.PAGENUM)*(ETF.NUMPERPAG)-(ETF.NUMPERPAG)+1}-<c:if test='${ETF.TOLCNT-(ETF.PAGENUM)*(ETF.NUMPERPAG)>=ETF.PAGENUM}'>${(ETF.PAGENUM)*(ETF.NUMPERPAG)}</c:if>
  <c:if test='${ETF.TOLCNT-(ETF.PAGENUM)*(ETF.NUMPERPAG)<ETF.PAGENUM}'>${ETF.TOLCNT}</c:if>条</span></div>
   
    <div class="pagination" targetType="navTab" totalCount="${ETF.TOLCNT}" numPerPage="${ETF.NUMPERPAG}" pageNumShown="${ETF.NUMPERPAG}" currentPage="${ETF.PAGENUM}"></div>
</div>
<script type="text/javascript">
$("#CUST_STATUS option[value='"+${ETF.CUST_STATUS}+"']").attr("selected","selected");
$("#CUST_CRED_TYPE option[value='"+${ETF.CUST_CRED_TYPE}+"']").attr("selected","selected");
</script>